package com.notes.utils;

import redis.clients.jedis.Jedis;
import redis.clients.jedis.JedisPool;

/**
 * @author tiny
 * @date 2021/12/20 19:46
 * @Description: 模拟redis工具类
 */
public class JedisUtil {

    private static final String REDIS_ADDR = "127.0.0.1";

    private static final int PORT = 6379;

    private static JedisPool jedisPool = new JedisPool(REDIS_ADDR,PORT);

    public static Jedis getJedis(){
        return jedisPool.getResource();
    }

}
